<!doctype html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link rel="stylesheet" type="text/css" href="../css/mui.css"/>
		<link href="../css/mui.min.css" rel="stylesheet" />
		<link rel="stylesheet" type="text/css" href="../css/general.css"/>
		<style type="text/css">
			.main{
				width: 100%;
			}
			.payok{
				width: 100%;
				color: #56C731;
				display: flex;
				justify-content: flex-start;
				align-items: center;
				padding: 1em;
			}
			.okdiv{
				width: 25px;
				height: 25px;
				background-color: #56C731;
				color: white;
				display: flex;
				align-items: center;
				justify-content: center;
				border-radius: 50%;
				margin: 0 0.8em 0  0;
				font-family: "黑体";
			}
			.pcontent{
				width: 100%;
				background-color: white;
				padding: 0.5em;
			}
			.ptext{
				color: #56C731;
				font-size: 2em;
				font-weight: 700;
				text-align: center;
				padding: 1em 0;
			}
			.pdata{
				width: 100%;
				margin: 0.5em 0;
			}
			.pdata>div{
				display: flex;
				justify-content: space-between;
				align-items: center;
				padding: 0.5em 0;
			}
			.pdata>div>span:first-child{
				color: #C7C7C7;
			}
			*{
				font-family: "微软雅黑";
			}
			.dbut{
				width: 100%;
				margin: 2em 0;
				padding: 1em;
			}
		</style>
	</head>

	<body>
		<header class="mui-bar mui-bar-nav hbg">
		    <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left colorw"></a>
		    <h1 class="mui-title">成功</h1>
		    <div class="hright" id="lbdiv">
		    	完成
		    </div>
		</header>
		<div class="mui-content">
		    <div class="main">
		    	<div class="payok">
		    		<div class="okdiv">
		    			√
		    		</div>
		    		支付成功
		    	</div>
		    	
		    	<div class="pcontent" id="payhtml">
		    		<!--
                    	作者：592176224@qq.com
                    	时间：2019-02-16
                    	描述：
                    
		    		<div class="ptext border-b">
		    			￥200.00
		    		</div>
		    		<div class="pdata">
		    			<div class="">
		    				<span id="">
		    					单据号
		    				</span>
		    				<span id="">
		    					CZ51651651653546
		    				</span>
		    			</div>
		    			<div class="">
		    				<span id="">
		    					交易时间
		    				</span>
		    				<span id="">
		    					2018-12-12 15:14:12
		    				</span>
		    			</div>
		    			<div class="">
		    				<span id="">
		    					支付方式
		    				</span>
		    				<span id="">
		    					现金支付
		    				</span>
		    			</div>
		    		</div>
		    		-->
		    	</div>
		    	
		    	<div class="dbut">
		    		<button id="againpay" type="button" class="mui-btn mui-btn-blue mui-btn-block">继续购买</button>
		    	</div>
		    	
		    	
		    </div>
		</div>
		<script src="../js/jquery.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="../js/mui.min.js"></script>
		<script src="../js/req.js" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript">
			
			 (function(m) {
                var Lcs = function() {}
                m.extend(Lcs.prototype, {
                    order_number: "",
                    createtime: "",
                    pay_sort: "",
                    pay_money:0,
                    onReady: function() {
                        var that = this;
                        m.init();
						try{
							var str = getrequest().data;
							var list = JSON.parse(str);
							that.order_number = list.order_number;
							that.createtime = list.createtime;
							that.pay_sort = list.pay_sort;
							that.pay_money = list.pay_money;
							that.sethtml();
							that.setadd();
						}catch(e){
							//TODO handle the exception
						}
						m.plusReady(function(){
							var view =  plus.webview.currentWebview();
							that.order_number = view.order_number;
							that.createtime = view.createtime;
							that.pay_sort = view.pay_sort;
							that.pay_money = view.pay_money;
							that.sethtml();
							that.setadd();
						})
						
						
                    },
                    sethtml:function(){
                    	var that = this;
                    	var str = '<div class="ptext border-b">￥'+
                    			that.pay_money+
		    					'</div><div class="pdata"><div class=""><span id="">单据号</span><span id="">'+
		    					that.order_number+
		    					'</span></div><div class=""><span id="">交易时间</span><span id="">'+
		    					that.createtime+
		    					'</span></div><div class=""><span id="">支付方式</span><span id="">'+
		    					that.pay_sort+
		    					'</span></div></div>'
                    	g("payhtml").innerHTML = str;
                    },
                    setadd:function(){
                    	g("againpay").addEventListener('tap',function(e){
                    		var cPage = plus.webview.currentWebview();
						    var bPage = cPage.opener();
						    var aPage = bPage.opener();
						    var dPage = aPage.opener();
						    cPage.close();
						    bPage.close();
						    aPage.close();
						    dPage.close();
						    //dPage.evalJS("cleargoods2();");
						    
                    	})
                    	
                    	g("lbdiv").addEventListener("tap",function(e){
							var cPage = plus.webview.currentWebview();
						    var bPage = cPage.opener();
						    var aPage = bPage.opener();
						    var dPage = aPage.opener();
						    var ePage = dPage.opener();
						    cPage.close();
						    bPage.close();
						    aPage.close();
							dPage.close();
							ePage.close();
						})
                    }
                    
                    
                    
                    
                });

                var lcs = new Lcs();
                lcs.onReady();
               
            })(mui)
			
		</script>
	</body>

</html>